package org.kernely.stream.userpage;

import org.kernely.stream.utils.KernelyMessageTable;
import org.kernely.ui.mvp.IKernelyView;

import com.vaadin.ui.Component;
import com.vaadin.ui.Panel;
import com.vaadin.ui.Table;
import com.vaadin.ui.VerticalLayout;


/**
 *	This view contain all the favorites of a user.
 */
@SuppressWarnings("serial")
public class StreamFavoritesView extends VerticalLayout implements IKernelyView {

	private Table favoritesTable;
	
	/**
	 * Constructor of the View.
	 */
	public StreamFavoritesView(){
		Panel favoritesPanel = new Panel();
		
		this.favoritesTable = new KernelyMessageTable(false);
		favoritesPanel.addComponent(favoritesTable);
		
		this.setSpacing(true);

		this.addComponent(favoritesPanel);
	}

	/**
	 * Unused method
	 */
	public final Component getComponent() {
		return this;
	}

	/**
	 * Get the table containing favorites messages.
	 * @return the table continaing favorites messages.
	 */
	public Table getFavoritesTable() {
		return favoritesTable;
	}
	
	

}
